//大作业H4

const int GuangMinPin = A0;
const int LedPin = 7;

void setup()
{
  // put your setup code here, to run once:
  Serial.begin(9600);
  pinMode(GuangMinPin, INPUT);
  pinMode(LedPin, OUTPUT);
}

void loop()
{
  // put your main code here, to run repeatedly:
  int value = analogRead(A0);
  if (value <= 600)
  {
    digitalWrite(LedPin, HIGH);
    delay(5000);
  }
  else
  {
    digitalWrite(LedPin, LOW);
  }
}
